﻿using System;

namespace eCommMongo.Core.Domain.Shippings
{
    public static class ShippingStatusExtension
    {
        public static string ToDesc(this ShippingStatus shippingStatus)
        {
            if (shippingStatus == ShippingStatus.ShippingNotRequired)
            {
                return "ShippingNotRequired";
            }
            else if (shippingStatus == ShippingStatus.NotYetShipped)
            {
                return "NotYetShipped";
            }
            else if (shippingStatus == ShippingStatus.PartiallyShipped)
            {
                return "PartiallyShipped";
            }
            else if (shippingStatus == ShippingStatus.Shipped)
            {
                return "Shipped";
            }
            else if (shippingStatus == ShippingStatus.Delivered)
            {
                return "Delivered";
            }
           
            else
            {
                throw new Exception(string.Format("paymentStatus {0} not exist", shippingStatus));
            }
        } 
    }
}